<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>web-components002</title>
</head>
<body>
  <my-button></my-button>
  <script src="./index.js"></script>
  <script>
    console.log('这是js代码');
  </script>
  <script>
    const element = document.querySelector('my-button');
    element.label = 'Click Me';
  </script>
</body>
</html>